package cn.stylefeng.guns.sys.modular.system.mapper;

import cn.stylefeng.guns.sys.modular.system.entity.BtyCwHuopei;
import cn.stylefeng.guns.sys.modular.system.entity.Huopei;
import cn.stylefeng.guns.sys.modular.system.model.params.BtyCwHuopeiParam;
import cn.stylefeng.guns.sys.modular.system.model.result.BtyCwHuopeiResult;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * 货赔表 Mapper 接口
 * </p>
 *
 * @author 
 * @since 2021-11-02
 */
@Mapper
public interface BtyCwHuopeiMapper extends BaseMapper<BtyCwHuopei> {

    /**
     * 获取列表
     *
     * @author 
     * @Date 2021-11-02
     */
    List<BtyCwHuopeiResult> customList(@Param("paramCondition") BtyCwHuopeiParam paramCondition);

    /**
     * 获取map列表
     *
     * @author 
     * @Date 2021-11-02
     */
    List<Map<String, Object>> customMapList(@Param("paramCondition") BtyCwHuopeiParam paramCondition);

    /**
     * 获取分页实体列表
     *
     * @author 
     * @Date 2021-11-02
     */
//    Page<BtyCwHuopeiResult> customPageList(@Param("page") Page page, @Param("paramCondition") BtyCwHuopeiParam paramCondition, @Param("dm") List dmList);

    List<BtyCwHuopeiResult> customPageList(@Param("paramCondition") BtyCwHuopeiParam paramCondition, @Param("date") String date, @Param("dm") List dmList);

    Page<BtyCwHuopeiResult> hpList(@Param("page") Page page, @Param("paramCondition") BtyCwHuopeiParam paramCondition, @Param("date") String date, @Param("dm") List dmList);

    /**
     * 获取分页map列表
     *
     * @author 
     * @Date 2021-11-02
     */
    Page<Map<String, Object>> customPageMapList(@Param("page") Page page, @Param("paramCondition") BtyCwHuopeiParam paramCondition);

    int count(@Param("code") String code, @Param("endTime") Date endTime);

    void delete(@Param("code") String code, @Param("endTime") Date endTime);

    boolean insertHp(@Param("list") List<BtyCwHuopei> list);

    List<String> dmList(@Param("name") String name);

    List<BtyCwHuopei> getHuopei(@Param("huopei") BtyCwHuopei param, @Param("date") String date);

    List<BtyCwHuopei> selectClassName(@Param("param") BtyCwHuopei param);

    List<BtyCwHuopei> selectTime(@Param("huopei") BtyCwHuopei param, @Param("date") String date);

    void updateNum(@Param("num") String num, @Param("shopCode") String shopCode, @Param("proCode") String proCode, @Param("endTime") Date endTime);

    void updateNumList(@Param("list") List<BtyCwHuopei> list);

    void update(BtyCwHuopei huopei);

    void updateList(@Param("list") List<BtyCwHuopei> list);

    Map hpDetail(@Param("param") BtyCwHuopei param, @Param("date") String date);

    BtyCwHuopei getTurn(@Param("huopei") BtyCwHuopei btyCwHuopei, @Param("date") String date);

    void updatePrice(BtyCwHuopei btyCwHuopei);

    void editPrice(@Param("cwHuopei") BtyCwHuopei cwHuopei, @Param("date") String date);

    List<String> getJsPrice(@Param("paramCondition") BtyCwHuopeiParam param, @Param("date") String date, @Param("dm") List dmList);

    List<String> dmListA();

    List<BtyCwHuopei> getIdList(@Param("proCode") String proCode, @Param("date") String date);

    void editAmount(@Param("list") List<BtyCwHuopei> list);

    void updateJs(BtyCwHuopei huopei);

    BigDecimal jsAmount(BtyCwHuopei huopei);

    BigDecimal zcjsAmount(BtyCwHuopei huopei);

    List<BtyCwHuopeiResult> exportList(@Param("date") String date, @Param("dm") List dmList);

    void editJsPrice(@Param("cwHuopei") BtyCwHuopei cwHuopei, @Param("date") String date);

    List<BtyCwHuopei> getJsIdList(@Param("proCode") String proCode, @Param("date") String date, @Param("shopCode") String shopCode);

    List<Map> getList(@Param("date") String date);

    List<BtyCwHuopei> getDmList(@Param("date") String date, @Param("list") List<String> dm);

    List<Map> cityList(@Param("name") String name);

    List<Map> cityNameList(@Param("name") String name, @Param("pid") Long pid);

//    List<String> getDm(@Param("city") String city, @Param("name") String name);
    List<String> getDm(@Param("cityId") Long cityId, @Param("name") String name, @Param("provinceId") Long provinceId);

    void deleteList(@Param("list") List<String> codeList, @Param("endTime") Date endTime);

    List<String> msgDmList(@Param("name") String name, @Param("provinceId") Long provinceId, @Param("cityId") Long cityId);

    List<String> getMsgList(@Param("date") String date, @Param("list") List<String> dmList);

    void updateSta(@Param("date") String date, @Param("list") List<String> list);

    Integer getSta(@Param("btyCwHuopei") BtyCwHuopei btyCwHuopei, @Param("date") String date);

    List<Map> getXjList(@Param("date") String date);

    List<BtyCwHuopei> getHuopeiAll(@Param("date") String date);

    void editHpPrice(@Param("cwHuopei") BtyCwHuopei cwHuopei, @Param("date") String date);

    List<BtyCwHuopei> getHpIdList(@Param("className") String className, @Param("scmClassCode") String scmClassCode, @Param("date") String date, @Param("shopCode") String shopCode);

    void editJsPriceList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    void editHpPriceList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<BtyCwHuopei> getJsList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date, @Param("shopCode") String shopCode);

    List<BtyCwHuopei> getHpList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date, @Param("shopCode") String shopCode);

    void editDhPrice(@Param("cwHuopei") BtyCwHuopei cwHuopei, @Param("date") String date);

    List<BtyCwHuopei> getIdsList(@Param("className") String className, @Param("date") String date);

    BigDecimal jlAmount(@Param("huopei") BtyCwHuopei huopei);

    BigDecimal dhAmount(@Param("huopei") BtyCwHuopei btyCwHuopei);

    void updateXj(BtyCwHuopei huopei);

    List<BtyCwHuopei> getJsLists(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<BtyCwHuopei> getHpLists(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<String> getJsCodes(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<String> getDhCodes(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<BtyCwHuopei> jlAmountList(@Param("list") List<BtyCwHuopei> list, @Param("date") Date date);

    List<BtyCwHuopei> dhAmountList(@Param("list") List<BtyCwHuopei> list, @Param("date") Date date);

    void editJsList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    void editHpList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<BtyCwHuopei> jsAmountList(@Param("list") List<BtyCwHuopei> list, @Param("date") Date date);

    List<BtyCwHuopei> zcjsAmountList(@Param("list") List<BtyCwHuopei> list, @Param("date") Date date);

    void updateXjList(@Param("list") List<BtyCwHuopei> list);

    List<BtyCwHuopei> getNoTurnList(String date);

    List<BtyCwHuopei> getTurnList(String date);

    List<BtyCwHuopei> getHuopeiList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<BtyCwHuopei> selectClassNameList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);

    List<BtyCwHuopei> selectTimeList(@Param("list") List<BtyCwHuopei> list, @Param("date") String date);
}
